import myRequest from '@/utils/myRequest'

export function createProduct(data) {
  return myRequest({
    url: '/api/product',
    method: 'post',
    data
  })
}

export function getProductList(limit) {
  return myRequest({
    url: '/api/product',
    method: 'get',
    data: {
      limit: limit
    }
  })
}

export function deleteProduct(productIds) {
  return myRequest({
    url: '/api/product/delete',
    method: 'POST',
    data: {
      products: productIds // Send product IDs as an array in the request body
    }
  })
}
